#include"progress_bar.h"

void bar()
{
    int i=0;
    char arr[101]={0};
    char ch[4]={'-','\\','|','/'};
    for(i=0;i<100;i++)
    {
        arr[i]='#';

        printf("[%c][%-100s][%3d%%][%c]\r",ch[i%4],arr,i+1,ch[i%4]);
        
        fflush(stdout);
        usleep(50000); 
    
    }
    printf("\n");


}
